package cn.kgc.ffzw.fuxi;

import java.util.Scanner;

public class TestH2O {
    public static void main(String[] args) {
        System.out.println("请输入温度");
        int temp=new Scanner(System.in).nextInt();
        H2O way=getTemp(temp);
        way.kill();
    }

    public static H2O getTemp(int temp){
        H2O h=null;

        if (temp<0){
            h=new Bing();
        }else if(temp<100){
            h=new Shui();
        }else{
            h=new Qi();
        }
        return h;
    }
}
